package user

import (
	"crmeb-common/global"
	"math/big"
	"time"
)

// UserClosing 用户结算表
type UserClosing struct {
	global.BaseModel
	ClosingNo string `json:"closingNo" gorm:"column=closing_no;comment:结算单号"`

	Uid int32 `json:"uid" gorm:"column=uid;comment:用户id"`

	ClosingType string `json:"closingType" gorm:"column=closing_type;comment:结算类型：bank = 银行卡 alipay = 支付宝 wechat=微信"`

	Cardholder string `json:"cardholder" gorm:"column=cardholder;comment:银行卡持卡人姓名"`

	BankCardNo string `json:"bankCardNo" gorm:"column=bank_card_no;comment:银行卡卡号"`

	BankName string `json:"bankName" gorm:"column=bank_name;comment:银行名称"`

	BankAddress string `json:"bankAddress" gorm:"column=bank_address;comment:开户地址"`

	AlipayAccount string `json:"alipayAccount" gorm:"column=alipay_account;comment:支付宝账号"`

	WechatNo string `json:"wechatNo" gorm:"column=wechat_no;comment:微信号"`

	PaymentCode string `json:"paymentCode" gorm:"column=payment_code;comment:微信收款二维码"`

	RealName string `json:"realName" gorm:"column=real_name;comment:真实姓名"`

	ClosingPrice big.Float `json:"closingPrice" gorm:"column=closing_price;comment:结算金额"`

	Balance big.Float `json:"balance" gorm:"column=balance;comment:用户余额"`

	Mark string `json:"mark" gorm:"column=mark;comment:备注"`

	AuditStatus int32 `json:"auditStatus" gorm:"column=audit_status;comment:审核状态：0-待审核，1-通过审核，2-审核失败"`

	RefusalReason string `json:"refusalReason" gorm:"column=refusal_reason;comment:拒绝原因"`

	AuditId int32 `json:"auditId" gorm:"column=audit_id;comment:审核员id"`

	AuditTime time.Time `json:"auditTime" gorm:"column=audit_time;comment:审核时间"`

	AccountStatus int32 `json:"accountStatus" gorm:"column=account_status;comment:到账状态：0-未到账，1-已到账"`

	ClosingProof string `json:"closingProof" gorm:"column=closing_proof;comment:结算凭证"`

	ClosingTime time.Time `json:"closingTime" gorm:"column=closing_time;comment:结算时间"`
}
